package com.txts.road.app.map.model.dto;

import java.io.Serial;
import java.io.Serializable;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;
import java.time.LocalDateTime;
import com.fasterxml.jackson.annotation.JsonFormat;
import java.math.BigDecimal;
import jakarta.validation.constraints.*;

/**
 * 位置点表单对象
 *
 * @author baoyr
 * @since 2025-07-17 10:42
 */
@Getter
@Setter
@Schema(description = "位置点表单对象")
public class LocationPointDTO implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Schema(description = "位置点ID")
    @NotNull(message = "位置点ID不能为空")
    private Long id;

    @Schema(description = "轨迹ID")
    @NotNull(message = "轨迹ID不能为空")
    private Long trackId;

    @Schema(description = "纬度")
    @NotNull(message = "纬度不能为空")
    private BigDecimal latitude;

    @Schema(description = "经度")
    @NotNull(message = "经度不能为空")
    private BigDecimal longitude;

    @Schema(description = "海拔(米)")
    private BigDecimal altitude;

    @Schema(description = "速度(km/h)")
    private BigDecimal speed;

    @Schema(description = "方向角(度)")
    private BigDecimal direction;

    @Schema(description = "精度(米)")
    private BigDecimal accuracy;

    @Schema(description = "记录时间")
    @NotNull(message = "记录时间不能为空")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime recordTime;

    @Schema(description = "创建时间")
    @NotNull(message = "创建时间不能为空")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;


}
